package cn.snowheart.boot.dependency;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.builder.SpringApplicationBuilder;
import org.springframework.boot.web.servlet.support.SpringBootServletInitializer;

/**
 * @author liuwanxiang
 * @version 2019/06/20
 */
@SpringBootApplication
public class DependencyApplication extends SpringBootServletInitializer {

    public static void main(String[] args) {
        SpringApplication.run(DependencyApplication.class, args);
    }

    /**
     * 用以Servlet容器加载SpringBoot应用
     *
     * @param builder SpringApplicationBuilder
     * @return SpringApplicationBuilder
     */
    @Override
    protected SpringApplicationBuilder configure(SpringApplicationBuilder builder) {
        return builder.sources(DependencyApplication.class);
    }
}
